export default {
  namespace: 'common',
  state: {
  	iscollapsed:false,
    breadcrumb:[
      {
        name:'首页',
        path:'/'
      }
    ],
    tabs:[
      {
        tabName:'通用列表',
        tabLink:'comList',
        tabIcon:'bars'
      },
      {
        tabName:'修改密码',
        tabLink:'editPassword',
        tabIcon:'edit'
      },
      {
      	SubMenuTabName:'一级菜单1',
      	SubMenuTabIcon:'appstore',
      	tabList:[
      		{
		        tabName:'通用表单',
		        tabLink:'comForm',
        		tabIcon:'edit'
		      },
		      
      		{
		        tabName:'通用列表',
		        tabLink:'comList',
        		tabIcon:'bars'
		      },
      	]
      }
    ]
  },
  reducers: {
    changeBreadcrumb(state,{ payload: breadcrumb }) {
      return {...state, ...breadcrumb}
    },
    changeLeftNav(state,{ payload: tabs }){
    	return {...state,...tabs}
    },
    toggleLeftNav(state,{ payload: iscollapsed }){
    	state.iscollapsed=!iscollapsed;
    	return {...state}
    }
  },
  effects: {},
  subscriptions: {},
}
